package com.wcs.exam.controller.auth.req;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.io.Serial;
import java.io.Serializable;

/**
 * <p>
 * Auth-用户考勤-请求参数
 * </p>
 *
 * @author wcs
 * @since 2024-07-17
 */
@Getter
@Setter
@Accessors(chain = true)
@Schema(description = "Auth-用户考勤-请求参数")
public class AuthUserAttendanceDetectAuthUrlReq implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @NotNull(message = "resource.user.attendance.attendance.type.not.null")
    @Schema(description = "考勤类型(1:模拟考试、2:正式考试、3:课时学习/考试)", requiredMode = Schema.RequiredMode.REQUIRED)
    private Integer attendanceType;

    @Schema(description = "关联ID", requiredMode = Schema.RequiredMode.REQUIRED)
    private Long relateId;

    @Schema(description = "课时ID")
    private Long periodId;

    @Size(max = 1024, message = "resource.user.attendance.redirect.url.max.length.error")
    @NotBlank(message = "resource.user.attendance.redirect.url.not.null")
    @Schema(description = "认证结束后重定向的回调链接地址。最长长度1024位。", requiredMode = Schema.RequiredMode.REQUIRED)
    private String redirectUrl;
}
